<?php
/**
 * Created by JetBrains PhpStorm.
 * User: Grom Hellscream
 * Date: 11/2/12
 * Time: 11:33 AM
 * To change this template use File | Settings | File Templates.
 */
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
$document = JFactory::getDocument();

$chitietkiluat = $this->get('chitietkiluat');
$canbo = $this->get('canbo');
$phongs = $this->get('phong');
if (count($phongs) > 1) 
    $phong = $phongs[0];
elseif (count($phongs) == 1)
    $phong = $phongs;
$donvis = $this->get('donvi');
if (count($donvis) > 1)
    $donvi = $donvis[0];
elseif (count($donvis) == 1)
    $donvi = $donvis;
$khoi = $this->get('khoi');
?>

<div id="crumbs">
    <div style="color: #222222;font-weight: normal;margin: 0;padding: 0">
        <a href="<?php echo JRoute::_('index.php?option=com_vast&view=vast') ?>">Trang chủ</a> »
        <span>Cơ cấu tổ chức</span> »
        <?php if (isset($khoi)): ?>        
        <a href="<?php echo JRoute::_('index.php?option=com_vast&view=donvitructhuoc&id=' . $khoi->id); ?>"><?php echo $khoi->ten ?></a> »                
        <?php endif; ?>
        <?php if (isset($donvi)): ?>
        <a href="<?php echo JRoute::_('index.php?option=com_vast&view=phongtructhuocs&id=' . $donvi->id); ?>"><?php echo $donvi->ten ?></a> »
        <?php endif; ?>
        <?php if (isset($phong)): ?>
        <span><?php echo $phong->ten; ?></span> »        
        <?php endif; ?>
        <a href="<?php echo JRoute::_('index.php?option=com_vast&view=chitietcanbo&id=' . $canbo->id); ?>"><?php echo $canbo->hoten; ?></a> »
        <span>Xem chi tiết kỉ luật</span>
    </div>
</div>

<div id="main" class="home">
    <h3 class="title green">Tra cứu thông tin kỉ luật của cán bộ <?php echo $canbo->hoten; ?></h3>
    
    <div class="single">
        <p style="text-align:justify;text-justify:inter-word;">
            <strong style="text-indent: 20px;">
                + Thời gian:
            </strong>
            <?php if (isset($chitietkiluat->thoigian) && !is_null($chitietkiluat->thoigian)) echo date('d/m/Y', strtotime($chitietkiluat->thoigian)); ?>
        </p>
            
        <p style="text-align:justify;text-justify:inter-word;">
            <strong style="text-indent: 20px;">
                + Hình thức:
            </strong>
            <?php if (isset($chitietkiluat->hinhthuc) && !is_null($chitietkiluat->hinhthuc)) echo $chitietkiluat->hinhthuc; ?>
        </p>

        <p style="text-align:justify;text-justify:inter-word;">
            <strong style="text-indent: 20px;">
                + Mức kỉ luật:
            </strong>
            <?php if (isset($chitietkiluat->noidung) && !is_null($chitietkiluat->noidung)) echo $chitietkiluat->noidung; ?>
        </p>

    </div>

    <hr style="height: 0px; border-top-color: #00ccff; border-right-color: #00ccff; border-bottom-color: #00ccff; border-left-color: #00ccff; border-top-width: 1px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-top-style: dashed; border-right-style: dashed; border-bottom-style: dashed; border-left-style: dashed;"/>
    
    <div style="float: left; width: 680px;">
        <?php
        if (isset($_SERVER['HTTP_REFERER']))
        {
            $url = htmlspecialchars($_SERVER['HTTP_REFERER']);
            echo '<a title="Quay lại" href="' . $url . '"><span style="left: 600px; position: relative;">&laquo; Quay lại</span></a>';            
        }
        ?>    
    </div>
    
</div>